<template>
	<view class="page page-equipment">
		<!-- 设备详情 -->
		<view class="box">
			<view class="title">服务及设施：</view>
			<view class="flex-row-start flex-wrap">
				<view class="item flex-row-start" v-for="(item, index) in hotelDetail.fac" :key="index">
					<view class="image" :style="{backgroundImage: 'url(' + (imgPath + item.img) + ')'}"></view>
					<view class="name">{{item.name}}</view>
				</view>
			</view>
		</view>
		<view class="hr7"></view>
		<!-- 设备详情 -->
		<view class="box">
			<view class="title">温馨提示：</view>
			<view class="content">
				<rich-text :nodes="hotelDetail.tips"></rich-text>
			</view>
		</view>
		<view class="box">
			<view class="title">酒店电话：</view>
			<view class="content tel">{{hotelDetail.tel}}</view>
		</view>
		<view class="hr7"></view>
		<!-- 设备详情 -->
		<view class="box">
			<view class="title">酒店介绍：</view>
			<view class="content">
				<rich-text :nodes="hotelDetail.content"></rich-text>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				imgPath: this.$Config.http_static, // 图片头
				hotelDetail: {}
			}
		},
		onLoad: function(options) {
			// 酒店详情
			this.$Http({
				url: 'hotelInfo',
				load: true,
				data: {
					id: options.hotelId,
					type: 'info',
				},
			}).then(res => {
				this.hotelDetail = res.data
			});
		},
		methods: {
		}
	}
</script>

<style lang="less">
	@import '@/common/css/variables.less';
	/* 设备详情 */
	.page-equipment{
		.box{
			background-color: #fff;padding: 30rpx;
			.title{font-size: 30rpx;padding-bottom: 20rpx;}
			.content{
				font-size: 28rpx;line-height: 48rpx;color: #646464;
				&.tel{color: @assist-color;}
			}
			.item{
				width: calc(100% / 3);margin-top: 20rpx;margin-bottom: 10rpx;
				.image{width: 48rpx;height: 32rpx;margin-right: 10rpx;background-position: 50%; background-size: auto 32rpx; background-repeat: no-repeat;}
				.name{font-size: 26rpx;color: #646464;}
			}
		}
	}
</style>
